<?php
use NoahBuscher\Macaw\Macaw;

Macaw::get('/', function() {
    echo 'Hello world!';
});

//新增一条路由
Macaw::get('/home', 'HomeController@home');

//错误路由
Macaw::$error_callback=function (){
    throw  new Exception('路由无法匹配 404 not found');
};

Macaw::dispatch();